<!--  -->
<template>
  <div>
    <p>{{$store.state.home.sum}}</p>
    <el-button @click="add">+</el-button>
  </div>
</template>

<script>
export default {
  data () {
    return {
    };
  },

  components: {},

  computed: {},


  methods: {
    add(){
      console.log('this.$store=',this);
        // this.$store.dispatch('home/add',1)
        this.$store.commit('home/ADD',1)

    }
  }
}

</script>
<style lang='less' scoped>
</style>